package com.base.thread.ch20;

/**
 * Created by xingyuchao@zto.cn on 2017-12-20.
 */
public abstract class BusincessException extends  Exception {

    public abstract Integer getCode();

    public abstract String getMsg();

    //重写fillInStackTrace方法会使得这个自定义的异常不会收集线程的整个异常栈信息，会大大提高减少异常开销。
    @Override
    public synchronized  Throwable fillInStackTrace(){
        return  this;
    }

}